import flask
import studentUrl

app = flask.Flask(__name__)


# @app.route("/")
# def hello_world():
#
#     return '<h1 style="color:red">Hello, World!</h2>'

@app.route("/testCssSelector")
def testCssSelector():
    fobj = open("testCssSelector.html", "rb")
    data = fobj.read()
    fobj.close()
    return data

@app.route("/home")
def home():
    fobj = open("home.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/")
def index():
    fobj = open("hplus-master/index.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/index_v1")
def index_v1():
    fobj = open("hplus-master/index_v1.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/index_v2")
def index_v2():
    fobj = open("hplus-master/index_v2.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/index_v3")
def index_v3():
    fobj = open("hplus-master/index_v3.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/index_v4")
def index_v4():
    fobj = open("hplus-master/index_v4.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/index_v5")
def index_v5():
    fobj = open("hplus-master/index_v5.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/form_basic")
def form_basic():
    fobj = open("hplus-master/form_basic.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/form_validate")
def form_validate():
    fobj = open("hplus-master/form_validate.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/form_advanced")
def form_advanced():
    fobj = open("hplus-master/form_advanced.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/form_wizard")
def form_wizard():
    fobj = open("hplus-master/form_wizard.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/typography")
def typography():
    fobj = open("hplus-master/typography.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/layouts")
def layouts():
    fobj = open("hplus-master/layouts.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/table_bootstrap")
def table_bootstrap():
    fobj = open("hplus-master/table_bootstrap.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/table_data_tables")
def table_data_tables():
    fobj = open("hplus-master/table_data_tables.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/table_basic")
def table_basic():
    fobj = open("hplus-master/table_basic.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/buttons")
def buttons():
    fobj = open("hplus-master/buttons.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/sweetalert")
def sweetalert():
    fobj = open("hplus-master/sweetalert.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/grid_options")
def grid_options():
    fobj = open("hplus-master/grid_options.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/empty_page")
def empty_page():
    fobj = open("hplus-master/empty_page.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/layerdate")
def layerdate():
    fobj = open("hplus-master/layerdate.html", "rb")
    data = fobj.read()
    fobj.close()
    return data


@app.route("/getParms")
def getParms():
    name = flask.request.args.get("name")
    age = flask.request.args.get("age")
    print(name)
    print(age)
    return name + age


if __name__ == "__main__":
    app.run(port=7890)
